﻿@model XHouseWeb.Models.RegisterModel
@{
    ViewBag.Title = "Nuevo Usuario";
}

@*@using (Html.BeginForm())
{
    @Html.AntiForgeryToken()
    @Html.ValidationSummary(true)

    <fieldset>
        <legend>Nuevo usuario</legend>
        @Html.Label(" Nombre de Usuario")
        <div>
            @Html.TextBoxFor(m => m.UserName)
            @Html.ValidationMessageFor(m => m.UserName)
        </div>
        @Html.Label("Contraseña")
        <div>
            @Html.PasswordFor(m => m.Password)
            @Html.ValidationMessageFor(m => m.Password)
        </div>
        @Html.Label(" Confirmación contraseña")
        <div>
            @Html.PasswordFor(m => m.ConfirmPassword)
            @Html.ValidationMessageFor(m => m.Password)
        </div>
        
        <button class="win-command">
            <span class="win-commandimage win-commandring">R</span>
            <span class="win-label">Guardar</span>
        </button>

        <a class="win-command" href="@Url.Action("Index","Home")">
            <span class="win-commandimage win-commandring">U</span>
            <span class="win-label">Cancelar</span>
        </a>
    </fieldset>
}*@

<div class="row">
    <div class="col-xs-12 col-md-10 col-md-offset-1">
        <div class="page-header">
            <h3>Registrar nuevo usuario</h3>
        </div>
        @using (Html.BeginForm(null, null, FormMethod.Post, new { @class = "form-horizontal", @role = "form" }))
        {
            @Html.AntiForgeryToken()
            @Html.ValidationSummary(true)
                        
            <div class="form-group">
                <label for="UserName" class="col-lg-2 control-label">Nombre de Usuario</label>
                <div class="col-lg-3">
                    @Html.TextBoxFor(model => model.UserName, new { @class = "form-control" })
                    @Html.ValidationMessageFor(model => model.UserName, String.Empty, new { @class = "help-block", @style = "color: red;" })
                </div>

            </div>
            <div class="form-group">
                <label for="Password" class="col-lg-2 control-label">Contraseña</label>
                <div class="col-lg-3">
                    @Html.TextBoxFor(model => model.Password, new { @class = "form-control", @type="password" })
                    @Html.ValidationMessageFor(model => model.Password, String.Empty, new { @class = "help-block", @style = "color: red;" })
                </div>
            </div>
            <div class="form-group">
                <label for="ConfirmPassword" class="col-lg-2 control-label">Confirmar Contraseña</label>
                <div class="col-lg-3">
                    @Html.TextBoxFor(model => model.ConfirmPassword, new { @class = "form-control", @type="password" })
                    @Html.ValidationMessageFor(model => model.ConfirmPassword, String.Empty, new { @class = "help-block", @style = "color: red;" })
                </div>
            </div>
            <div class="form-group">
                <div class="col-lg-offset-2 col-lg-3">
                    <button class="btn btn-primary">Guardar</button>
                    <a class="btn btn-danger" href="@Url.Action("Index", "Home")">Cancelar</a>
                </div>
            </div>
                   
        }

    </div>
</div>
